import Vue from 'vue'
import Router from 'vue-router'
import children from './childrenList' // 公共的子路由

Vue.use(Router)

// 公共的路由菜单
const routeList = [
  { path: '/',
    meta: { title: '首页', noCache: false },
    component: (resolve) => require(['@/views/home'], resolve),
    hidden: true
  },
  ...children
]

export default new Router({
  // base: '/flightControl/',
  scrollBehavior: () => ({ y: 0 }),
  routes: routeList
})